package cn.virens.database.mysql.mapper.sys;

import java.util.List;
import java.util.Map;

import org.apache.ibatis.annotations.Param;

import cn.virens.database.mysql.model.sys.SysResource;
import tk.mybatis.mapper.common.Mapper;

public interface SysResourceMapper extends Mapper<SysResource> {

	List<String> getAll(@Param("name") String name);

	List<String> getResources(@Param("account") String account);

	/**
	 * code, name, linkurl, icon
	 * 
	 * @param account
	 * @return
	 */
	List<Map<String, Object>> getResourcesByAccount(@Param("account") String account);

	List<Map<String, Object>> getSimpleResource(@Param("parent") String parent);

	int updateParent(@Param("code") String code, @Param("parent") String parent);

}